import request from '../utils/request';
//查询所有的部门数据
export const queryEmpApi=(name,gender,begin,end,page,pageSize)=>
                 request.get(`/emps?name=${name}&gender=${gender}&begin=${begin}&end=${end}&page=${page}&pageSize=${pageSize}`);
export const addEmpApi=(emp)=> request.post('/emps',emp)

//查询所有员工的数据
export const queryAllEmp=()=> request.get('/emps/list')

//根据id查询员工
export const queryByIdApi=(id)=>request.get(`/emps/${id}`)

//修改员工
export const updateEmpApi=(emp)=>request.put('/emps',emp)

//批量删除员工
export const deleteEmpByIdApi=(ids)=>request.delete(`/emps?ids=${ids}`)